﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Payroll.Common;

namespace Payroll.BusinessLogic.CustomerManager
{
    public partial interface ICustomerService
    {        
        /// <summary>
        /// Saves the specified c.
        /// </summary>
        /// <param name="c">The c.</param>
        /// <returns>ID of Customer</returns>
        int Save(Customer c);
        /// <summary>
        /// Deletes the specified list.
        /// </summary>
        /// <param name="List">The list.</param>
        /// <returns></returns>
        int Delete(List<int> List);
        /// <summary>
        /// Gets all customer.
        /// </summary>
        /// <param name="filter">The filter.</param>
        /// <param name="pageSize">Size of the page.</param>
        /// <param name="pageIndex">Index of the page.</param>
        /// <returns>List of Customer</returns>
        PagedList<Customer> GetAllCustomer(CustomerSearchResult filter, int pageSize = int.MaxValue, int pageIndex = 0);
        /// <summary>
        /// Gets all customer.
        /// </summary>
        /// <param name="pageSize">Size of the page.</param>
        /// <param name="pageIndex">Index of the page.</param>
        /// <returns></returns>
        PagedList<Customer> GetAllCustomer(int pageSize = int.MaxValue, int pageIndex = 0);
        /// <summary>
        /// Gets the customer by id.
        /// </summary>
        /// <param name="customerId">The customer id.</param>
        /// <returns></returns>
        Customer GetCustomerById(int customerId);
        /// <summary>
        /// Gets the name of the customer by.
        /// </summary>
        /// <param name="name">The name.</param>
        /// <returns></returns>
        Customer GetCustomerByName(string name = "");
        #region Profile
        /// <summary>
        /// Saves the profile.
        /// </summary>
        /// <param name="p">The p.</param>
        /// <returns>ID of Profile</returns>
        int SaveProfile(profile p);
        int DeleteProfile(List<int> ProfileIDColection);
        List<profile> GetAllProfileByCustomerID(int customerId, int ObjectID = 0);
        #endregion
        #region ProfileProperty
        int SaveProfileProperty(ProfileProperty pr);
        int DeleteProfileProperty(List<int> profilePropertyColection);
        List<ProfileProperty> GetAllProfilePropertyByCustomerId(int customerId);
        #endregion
        #region ProfileFinan
        /// <summary>
        /// Saves the profile finan.
        /// </summary>
        /// <param name="pr">The pr.</param>
        /// <returns>Id of ProfileFinan</returns>
        int SaveProfileFinan(ProfileFinan pr);
        /// <summary>
        /// Deletes the profile finan.
        /// </summary>
        /// <param name="profileFinanColection">The profile finan colection.</param>
        /// <returns></returns>
        int DeleteProfileFinan(List<int> profileFinanColection);
        /// <summary>
        /// Gets all by customer id.
        /// </summary>
        /// <param name="customerId">The customer id.</param>
        /// <returns></returns>
        List<ProfileFinan> GetAllByCustomerId(int customerId);
        #endregion
        #region FeesSchedule
        int SaveFeesSchedule(FeesSchedule f);
        int DeleteFeesSchedule(List<int> feesScheduleColection);
        List<FeesSchedule> GetAllFeesScheduleByCustomerId(int customerId);
        #endregion
        #region advande
        /// <summary>
        /// Saves the specified c.
        /// </summary>
        /// <param name="c">The c.</param>
        /// <param name="ListProfile">The list profile.</param>
        /// <param name="ListProfileProperty">The list profile property.</param>
        /// <param name="ListProfileFinan">The list profile finan.</param>
        /// <param name="ListFeesSchedule">The list fees schedule.</param>
        /// <param name="ListRelation">The list relation.</param>
        /// <returns>Customer Info</returns>
        Customer Save(Customer c, List<profile> ListProfile, List<ProfileProperty> ListProfileProperty, List<ProfileFinan> ListProfileFinan, List<FeesSchedule> ListFeesSchedule, List<Relationships> ListRelation);
        #endregion
        #region Object
        /// <summary>
        /// Gets the object by id.
        /// </summary>
        /// <param name="ObjectTypeId">The object type id.</param>
        /// <returns>List of object by ObjectTypeId</returns>
        List<Objects> GetObjectById(int ObjectTypeId);
        #endregion
        #region Genaral Case Work
        CutomerType SaveCutomerType(CutomerType c);
        int DelateCutomerType(int cutomerTypeId);
        List<CutomerType> GetCustomerType(string customerType = "");
        string GetCaseWork(int customerTypeId);
        #endregion
        #region CustomerFilter
        CustomerSearchResult GetCustomerSearchResultbyId(int customerId);
        void SaveCustomerFilter(CustomerSearchResult c);
        #endregion
        #region Dashboard
        List<Dashboard> GetDashboard();
        List<Dashboard> GetDashboardInterviewDate();
        List<Dashboard> GetDashboardPassbook();
        List<Dashboard> GetDashboardAppointment();
        List<DashboardGenaral> GetDashboardGenaral();
        #endregion
        #region Relationship
        /// <summary>
        /// Saves the relationship.
        /// </summary>
        /// <param name="List">The list.</param>
        /// <param name="customerId">The customer id.</param>
        void SaveRelationship(List<Relationships> List, int customerId);
        /// <summary>
        /// Gets the list.
        /// </summary>
        /// <param name="customerId">The customer id.</param>
        /// <returns></returns>
        List<Relationships> GetListRelationship(int customerId);
        List<Customer> GetNotRelationship(CustomerSearchResult cust, int customerId);
        #endregion
    }
}
